<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        const a ={
            name:'zhangsan',
            age:18,
            isMale:true
        }
        const {name,...rest}=a
        rest.isMale = false
        console.log(a);
        console.log(rest);
    </script>
</body>
</html>